package com.foxnicweb.app.constants.enums.patent;

import com.github.foxnic.api.constant.CodeTextEnum;
import com.github.foxnic.commons.reflect.EnumUtil;
import org.github.foxnic.web.constants.enums.bpm.ApprovalCatalog;

/**
 * 这里与红坚果保持一致
 * */
public enum MemberType implements CodeTextEnum {

	// 初始阶段
	customer("客户"),
	// 检索阶段
	sales("销售"),
	flow("流程"),
	ipr("IPR"),
	applicants("申请人"),
	inventors("发明人"),
	// 撰稿阶段
	contact("联系人"),
	patent_agent("送件代理⼈"),
	;

	private String text;
	private MemberType(String text)  {
		this.text=text;
	}

	public String code() {
		return this.name();
	}

	public String text() {
		return text;
	}

	public static ApprovalCatalog parseByCode(String code) {
		return (ApprovalCatalog) EnumUtil.parseByCode(ApprovalCatalog.values(),code);
	}

}
